import React, { useEffect, useState } from "react";
import { get_data } from "../../api";
import style from '../../style/index.module.css'
import Floor from "../../components/Floor";
import Search from '../../components/Search'
function Index() {
  const [data, setData] = useState([]);
  useEffect(() => {
    (async () => {
      let res = await get_data();
      console.log(res,'1111')
      if (res.status === 200) {
        setData(res.data);
      }
    })();
  }, []);
  console.log("data", data);



  return (
    <div>
      <div className={style.search}>
        <Search></Search>
      </div>
      <div className={style.swiper}> 
          轮播图
      </div>
      <div className={style.Navigation}>
          <Floor></Floor>
      </div>
      <div className={style.animation}>
        动画
      </div>
      <div className={style.animation}>
        动画
      </div>
      
      精选推荐
    </div>
  );
}

export default Index;
